UrlRequestJob

interface UrlRequestJob

Represents the url request job for a URL request. Allows you to override the response data for the URL request.

Types

Link copied to clipboard
interface Id
An identifier of the UrlRequestJob.
Link copied to clipboard
interface Options
The options needed to initialize UrlRequestJob.

Functions

Link copied to clipboard
abstract fun complete()
Notifies the engine that all the response data chunks are written and the request should be completed.
Link copied to clipboard
abstract fun fail()
Notifies the engine that an error occurred during writing the response data and the request should be failed.
Link copied to clipboard
abstract fun id(): UrlRequestJob.Id
Returns the identifier of this URL request job.
Link copied to clipboard
abstract fun write(data: Array<Byte>)
Appends a chunk of the response data to the URL request.